/**
 * 配置字段的公用方法 ---锦程
 *
 */

// eslint-disable-next-line no-undef
FilterFuns = {
  basicFilterOption: function(valueArray, formInfo) {
    return {
      labelWidth: 90,
      emptyBtn: false,
      submitBtn: false,
      enter: false,
      column: [
        {
          label: "工单编号",
          prop: "workOrderId",
          type: "input",
          span: 8,
          display: true
        },
        {
          label: "状态",
          prop: "workOrderStatusId",
          type: "select",
          span: 8,
          display: true,
          dicData: valueArray["workOrderStatusId"],
          change: ({ value, column }) => {
            formInfo[column.prop] = value;
          }
        },
        {
          label: "客户姓名",
          prop: "customer_name",
          type: "input",
          dataType: "string",
          display: true,
          span: 8
        },
        {
          label: "身份证号",
          prop: "id_number",
          span: 8,
          dataType: "string",
          display: true,

          type: "input"
        },
        {
          label: "申请号",
          prop: "application_number",
          span: 8,
          dataType: "string",
          display: true,
          type: "input"
        },
        {
          label: "联系电话",
          prop: "phone_number",
          span: 8,
          dataType: "string",
          display: true,
          type: "input"
        }
      ]
    };
  },
  advanceFilterOption: function(valueArray, formInfo) {
    return {
      column: [
        {
          label: "业务类型",
          prop: "business_type",
          type: "select",
          span: 8,
          display: false,
          dicData: valueArray["business_type"],
          change: ({ value, column }) => {
            formInfo[column.prop] = value;
          }
        },
        {
          label: "工单来源",
          prop: "source",
          type: "select",
          span: 8,
          display: false,
          dicData: valueArray["source"],
          change: ({ value, column }) => {
            formInfo[column.prop] = value;
          }
        },
        {
          label: "创建人姓名",
          prop: "createUser",
          span: 8,
          display: false,
          dataType: "string",
          type: "input"
        },
        {
          label: "创建人工号",
          prop: "CREATE_AGENTID",
          span: 8,
          display: false,
          dataType: "string",
          type: "input"
        },
        {
          label: "优先级",
          prop: "priority",
          type: "select",
          span: 6,
          display:false,
          dicData:valueArray['priority'],
          change: ({
            value,
            column
          }) => {
            formInfo[column.prop] = value;
          }
        },
        {
          label: "创建时间",
          prop: "createTime",
          valueFormat: "yyyy-MM-dd HH:mm:ss",
          type: "datetimerange",
          display: false,
          defaultTime: ["00:00:00", "23:59:59"],
          span: 10,
          change: ({ value, column }) => {
            formInfo[column.prop] = value;
          }
        },
        {
          label: "当前处理人",
          prop: "current_handler_name",
          span: 16,
          formslot: true,
          display:false,
        },
      ]
    };
  }
};